package com.whut.service;

import com.whut.model.*;
import com.whut.model.ContractCheckTask;
import com.whut.model.Contracttaskaccept;
import com.whut.model.MachineInfo;

import java.text.ParseException;
import java.util.List;

public interface EquipService {
    Object getEquipCheckResult(String equipNums, int checkId, int fourthId);

    /**
     * @author: liukang
     * @Description: 导入excel文件
     * @date: 2020/7/12 19:44
     * @param:
     * @return:
     */
    public String importMachineInfoExcel(String filePath,int projectId,int projectType,int equipType,int machineType) throws ParseException;

    /**
     * @author: liukang
     * @Description: 录入
     * @date: 2020/6/21 11:08
     * @param: machineinfo
     * @return: "success" or "error"
     */
    public String saveMachineInfo(MachineInfo machineinfo);

    /**
     * @author: liukang
     * @Description: 真删除
     * @date: 2020/6/21 11:08
     * @param: mKey
     * @return: "success" or "error"
     */
    public String deleteMachineInfo(Integer mKey);

    /**
     * @author: liukang
     * @Description: 假删除
     * @date: 2020/6/21 11:08
     * @param: mKey
     * @return: "success" or "error"
     */
    public String deleteMachInfoByNY(Integer mKey);

    /**
     * @author: liukang
     * @Description: 编辑
     * @date: 2020/6/21 11:04
     * @param: machineinfo
     * @return: "success" or "error"
     */
    public String updateMachineInfo(MachineInfo machineinfo);

    /**
     * @author: liukang
     * @Description: 拿表里的所有信息
     * @date: 2020/6/21 12:25
     * @param: pageNum，pageSize
     * @return: List<MachineInfo>
     */
    public Object getMachineInfoByPage(int pageNum,int pageSize);

    /**
     * @author: liukang
     * @Description: 搜索时调用的方法，根据搜索参数拿到数据
     * @date: 2020/6/21 11:04
     * @param: searchParams，pageNum，pageSize
     * @return: List<MachineInfo>
     */
    public Object getMachineInfoBySearchParams(String searchParams,int pageNum,int pageSize);

    /**
     * @author: liukang
     * @Description: 根据工程id获取信息，即展示所有信息时调用的方法
     * @date: 2020/6/21 11:05
     * @param: projectName，pageNum，pageSize
     * @return: List<MachineInfo>
     */
    public Object getMachineInfoByProjectId(Integer projectId,int pageNum,int pageSize);

    /**
     * @author: liukang
     * @Description: 根据工程id和设备类型获取信息，即下拉框选择设备类型时调用此方法
     * @date: 2020/6/21 11:07
     * @param: projectName，machineType，pageNum，pageSize
     * @return: List<MachineInfo>
     */
    public Object getMachineInfoByEquipType(Integer projectId,Integer machineType,int pageNum,int pageSize);
    public Object getMachineInfoByProjectIdAndEquipType(Integer projectId,Integer equipType,int pageNum,int pageSize);
    /**
     * @author xiaxing
     *通过一三级获取对应设备的设备编号，用来判断插入时不能有相同设备编号
     * @date 2021/4/8 11:08
     * @param: ()
     * @return java.lang.
     */
    public Object getEquipNUmByProjectIdAndEquipType(Integer projectId,Integer equipType);

    /**
     * @author: liukang
     * @Description: 在体系里根据number拿到parametername
     * @date: 2020/7/23 12:23
     * @param:
     * @return:
     */
    public String getName4ByName4Id(int number);



    Object getNoPromblemEquipNum(int checkId, int fourthId);

    //Object getProjectName();

    List<ContractCheckTask> getProjectNameByTaskId(int taskId);


    String getProjectCategoryByProjectId(int projectId);

    String getProjectNameByProjectId(int projectId);

    List<Contracttaskaccept> getTaskOptionsByClientId(Integer contractId);

    Object getEquipUncheckedItems(String eqipNum, int checkId, int fourthId);

    List<ParPrefixSystem> getSecondLevel();

    List<ParPrefixSystem> getThirdAndFourthLevel(int number);

    String getParameterNameByNumber(int number);

    Object getMachineInfoRecordByProjectId(int projectId);

    int getParameterNameByPreNumAndNum(String pName, int preNum);

    /**
     * Author:yjh
     * Description:通过委托+任务+项目（checkId）获取所有设备信息
     * Create date:2021/3/4 14:27
     */
    Object getAllequipInfoByClientTaskCheckid(String client,String task,String check,String startTime,String endTime);

    /**
     * Author:yjh
     * Description:通过check查询pcd表的projectId并去重
     * Create date:2021/3/8 13:04
     */
//    List<Equipscore> getAllEquipScoreBycheckId(String check);

    /**
     * Author:yjh
     * Description:通过checkId查询所有设备评分信息
     * Create date:2021/3/10 15:50
     */
    Object getAllEquipscoreBycheckId(String check);

    /**
     * Author:yjh
     * Description:根据check与equiptype查询equipscore
     * Create date:2021/3/11 16:36
     */
    Object getEquipscoreBycheckIdEquipType(String check,String equipType);

    /**
     * Author:yjh
     * Description:通过checkId查询equipType
     * Create date:2021/3/11 17:21
     */
    Object getEquiptypeByCheckId(String check);
}
